Angle Basis: a Generative Model and Decomposition for Functional Connectivity

Functional connectivity (FC) is one of the most common inputs to fMRI-based predictive models, due to a combination of its simplicity and robustness. However, there may be a lack of theoretical models for the generation of FC. In this work, we present a straightforward decomposition of FC into a set of basis states of sine waves with an additional jitter component. We show that the decomposition matches the predictive ability of FC after including 5–10 bases. We also find that both the decomposition and its residual have approximately equal predictive value, and when combined into an ensemble, exceed the AUC of FC-based prediction by up to 5%. Additionally, we find the residual can be used for subject fingerprinting, with 97.3% same-subject, different-scan identifiability, compared to 62.5% for FC. Unlike PCA or Factor Analysis methods, our method does not require knowledge of a population to perform its decomposition; a single subject is enough. Our decomposition of FC into two equally-predictive components may lead to a novel appreciation of group differences in patient populations. Additionally, we generate synthetic patient FC based on user-specified characteristics such as age, sex, and disease diagnosis. By creating synthetic datasets or augmentations we may reduce the high financial burden associated with fMRI data acquisition.


Introduction and Related Work
Functional magnetic resonance (fMRI) uses the blood oxygen level-dependent (BOLD) signal to map blood flow in the brain [2], which is correlated to neural activity through the hemodynamic response function [39]. Early work in fMRI utilized statistical techniques on voxel intesities to measure brain region activation and group differences [32]. More recently, functional connectivity (FC), the temporal Pearson correlation of BOLD signal across different regions of the brain, has been used to characterize brain state [16]. Regions are delineated using either a template [37] or ICA [8].
FC has recently been used for the prediction of subject age [25], sex [50], race [33], or schizophrenia (SZ) diagnosis [24], at levels that in some cases meet or exceed prediction using genetic information [5]. It has also been used to flag possible pre-clinical Alzheimer's disease by predicting a subject's brain age based on FC and comparing with actual age [30]. Interestingly, it has even been used for mechanistic studies of aggression in response to olfactory stimulus [31], the traditional province of statistical fMRI techniques. In the hospital setting, it may be used in evaluating the severity and monitoring the treatment of concussions [18]. Dynamic FC, using either window-based or non-window-based [4] methods, has also been explored in the literature, with some studies showing benefit over static FC [40] and others disagreeing [23].
Many studies have explored alternative measures of connectivity, such precision matrix-based (partial) correlation [20], distance correlation [13] [28], effective connectivity [43], or phase lock value (PLV) [14]. In general, these methods have been found to be largely similar [1] in terms of usefulness. For example, partial correlation may have better test-retest reliability, but lose the meaning of regionregion synchronization inherent in FC [29]. Geerligs et al. [13] found that Pearson correlation has slightly worse results compared to distance correlation. In fact, FC and distance correlation-based connectivity maps are largely indistiguishable [28]. BrainNetCNN [19], by contrast, works directly on time series data, but the resulting convolutional filters are not as interpretable as FC maps. Since FC is an established method, many recent papers focus on novel approaches. It should be noted, however, that even since the days of ANOVA-based statistical methods, fMRI has suffered from a reproducibility crisis [3] [10]. Therefore a focus on simplicity and reproducibility [48] may be preferred.
In terms of generative models which aim to simulate brain dynamics, the main focus has been on structural equation modeling (SEM) or dynamic causal modeling (DCM), used to generate effective connectivity [26]. Unfortunately, DCM has a high computational complexity that makes it unsuitable for working with a large number of regions [17] [41]. Additionally, even the highest resolution fMRI only identifies the averaged activity of many individual neurons, further blurred by the hemodynamic response function [39]. Graphical models use FC, or some other connectivity method, as the basis for determining graph edge weights and then use thresholding to binarize these edges [21]. In effect, FC is the foundation on which most such methods are built.
Zhao et al. [51] and others [27] have used GANs to help discriminate between patients and healthy controls. Tan et al. [47] have used a manifold-regularized Wasserstein distance GAN to achieve modest prediction gains. However, these GAN-based methods fail to model the underlying time-varying BOLD signal that underpins FC. Therefore they cannot be used for decomposition, dimensionality reduction, or easy interpretation as can our work.
In this work, we provide a theoretical basis for decomposition of FC based on regions of in-phase or out-of-phase sine waves, representing the bandpass-filtered BOLD signal at a region of interest (ROI). In conceptual terms, it has some similarity to the PLV determined using the Hilbert transform [14]. The PLV, however, is not widely used in predictive models [49], and our own validation experiments have shown it performs much worse than other measures of connectivity when used for prediction tasks (see Supplemental Materials). By combining a sine-wave decomposition with a jitter value at each ROI, we are able to reconstruct the majority of FC, creating both a useful decompostion and a useful residual. Typical MRI studies require $500-$1000 per subject for data acquisition [45]. Using our model for the generation of synthetic FC based on specific phenotype settings, we may alleviate some of the high financial burden of fMRI data acquisition, allowing greater accessibility to this modality.

Methods
We describe angle basis as an approximation of the Fourier series representation of the time domain BOLD fMRI signal x(t), from which FC is derived. We motivate the underlying model by a connection to the well-known but less widely used PLV. Note that the FC is defined as the Pearson correlation of the time domain signals between regions c and d: Any time domain signal can be represented in a basis of complex sinusoids via the Fourier transform: The Hilbert transform, acting on the time domain signal, imparts a π/2 phase shift to every complex sinusoid depending on the sign of the sinusoid frequency: Here p.v. represents the Cauchy principal value of the improper integral. Using the Hilbert transform, one may change the original signal into an analytic signal x a (t) containing only positive frequencies. x The analytic signal may be factorized into a low-frequency amplitude envelope a(t) and a phase term θ(t), so long as Bedrosian's theorem [6] holds, i.e. as long as the support of a(t) and θ(t) are different. This may be the case for fMRI signals, which are typically bandpass filtered.
x a (t) = a(t)e iθ(t) The connectivity between two regions c, d may be quantified as the PLV, a measure of the dispersion of phase differences between the two regions [14].
Although PLV has been widely used in neuroscience [22], it is dependent on the passband and has relatively poor predictive ability (see Supplemental Materials). Additionally, one may wish to work directly with the FC. Given this motivation, we present a simplified but more robust model.

Angle Basis Decomposition
First, we represent the signal as a Fourier series, assuming, as in the case of the PLV, that the amplitude envelope of the passband-filtered signal is constant with respect to the phase signal.
A n sin(ω n t + θ n ) In the simplest case, we approximate the BOLD signal at each region c as a single sine wave with arbitrary constant amplitude and phase.
x c (t) = A c sin(ωt + θ c ) Angle Basis Construction Figure 1: Example of the angle basis reconstruction of one representative subject from the PNC dataset. The prominent block corresponds to the default mode network (DMN). The scan is probably of a female, due to the high within-DMN connectivity [11]. Here only one basis is used.
The correlation between ROIs c and d is then simply the cosine of the phase difference.
We reduce the number of frequencies required to decompose the signal by introducing a jitter component, which models the signal at a region "jittering" such that it becomes uncorrelated with all other regions.ρ Here the superscript (n) refers to the correlation in the n th basis. Each scan can be modeled with up to N bases, where the bases represent either different temporal regions or orthogonal sinusoids of different frequencies. We then calculate the overall correlation between regions c, d as follows: We understand this formula is only valid when amplitudes are the same across all basis sinusoids; however we find this model to be useful regardless. Additionally, differences in window lengths or amplitudes can be incorporated into the j term in a uniform way.
The decomposition is estimated via gradient descent by minimizing the RMSE between the reconstructed and true FC, i.e. the residual r cd .
Here R is the number of regions in the remplate, ρ cd ,ρ cd are the true and estimated FC values, respectively, and r cd is the residual. Values of jitter that become less than 0 or greater than 1 are clipped to those values while phase angles wrap around. Figure 1 shows the decomposition of a representative's subject's FC into a single basis plus residual. The template we used used contains 264 regions, meaning that each basis must contain 528 values for phase and jitter. In section 3.4, we show that 5-10 bases are enough to recreate the predictive capacity of FC. In contrast, there are 34,716 non-duplicate values in a subject's FC.
Angle basis estimation is carried out using PyTorch [34] with CUDA support. 2 Our source code may be found at https://github.com/aorliche/AngleBasis. Training time is approximately one second per subject for a one basis decomposition, up to 10 seconds for higher numbers of basis sinusoids, using a single GPU.

Experiments
We validate the usefulness of the decomposition in five downstream tasks: • Identification of the same subject from different scans • Prediction of age, sex, race, and schizophrenia diagnosis across two different datasets • Transfer of models trained on one dataset to predict sex or race to another dataset • Prediction using reduced feature numbers (feature selection) • Generation of synthetic FC Prediction was carried out using vectorizations of the true FC matrix, angle basis reconstruction, angle basis residual, or ensemble of angle basis and residual. In addition, a Factor Analysis was used to create latents and residuals for the identifiability task and age prediction. Identifiability was carried out by cosine similarity, which was found to give better results than Euclidean distance for all inputs tested. A deep autoencoder (AE) with 2 hidden layers of 2000 and 2000 neurons with ReLU activation was also used to create a reconstruction/residual for the prediction tasks.
The models used for prediction were simple Ridge and Logistic Regression models, from the scikitlearn implementation [35], 3 with a maximum of 1000 iterations and regularization parameters α = 1 and C = 1, respectively. Models were evaluated using an 80/20 train test split over 20 bootstrap repetitions. When using Ridge Regression (age prediction), both training and test sets were centered using the mean age of the training set. For race prediction, only African Ancestry (AA) and European Ancestry (EA) ethnicities were used, because our datasets were enriched for these groups, with other ethnicities making up less than 10% of subjects. Although FC-based predictions are not always improved by using more expressive models [36], we include a comparison with an MLP and BrainNetCNN [19] in the Supplemental Materials.

Datasets
We tested our model on two different, large, widely-used datasets available to researchers via application. Both datasets were pre-processed with SPM12, 4 including intra-subject co-registration, warping to MNI space, smoothing with a 5mm FWHM kernel, temporal bandpass filtering from 0.01 to 0.15 Hz, and time series extraction using the 264-region Power atlas [37]. Power atlas regions are discrete balls of 5mm radius from which average BOLD signal was extracted.

Philadelphia Neurodevelopmental Cohort (PNC)
The PNC dataset is a large, widely used dataset consisting of children and young adults 8-22 years old, 1,529 of whom have fMRI scans [42] and over 9,000 of whom have genetic information [15]. Most subjects have three scans, one for a resting state, one for a working memory [38], and one for an emotion identification in-scanner task. A wide variety of phenotype information is available, including sex, race, cognitive battery, and questionnaire info [9]. Subjects were not specifically selected due to prior neurological problems. Of subjects having scans, 725 are male, 804 are female, 660 are AA ethnicity, 690 are EA ethnicity, and 179 are of other ethnicity. More detailed phenotype data and correlations are provided in the Supplemental Materials.

Bipolar and Schizophrenia Network for Intermediate Phenotypes (BSNIP)
The BSNIP dataset is a large multi-site fMRI dataset acquired to further understand schizophrenia, schizoaffective disorder, and bipolar disorder [46].

Identification of Individuals
We find that taking the residual of the angle basis reconstruction using one basis greatly increases the identification rate of subjects in the PNC dataset, from 62.5% using FC to 97.3% using the angle basis residual (see Figure 2). In addition, we find that a Factor Analysis residual (not PCA) with N = 10 factors also increases identification rate to 84.9%. Previous work has found similar different-task same-subject identification as our FC result [12], as well as a slightly better result using a Factor Analysis-like method to produce a residual [7]. However, as seen in Figure 3, we find that the Factor Analysis method is not amenable to high prediction accuracy. Additionally, Factor Analysis, PCA, and the deep AE require knowledge of and have a dependence on the entire dataset. Figure 3 shows that prediction RMSE of age in the PNC dataset is comparable between FC and the first residual, and slightly better for the ensemble of residual and angle basis reconstruction. In addition, we see that removing the confounding effects of sex and race results in much stronger age prediction accuracy. In fact, increasing the dataset by a factor of four still doesn't match the accuracy of predicting within sex and race-matched groups. We also note that the Factor Analysis method does not have strong predictive fidelity for age prediction, and the deep AE ensemble performs poorly in predictive tasks. PCA was similar to the deep AE (not shown). We additionally tested the prediction fidelity of sex and race in the PNC dataset; and sex, race, and schizophrenia diagnosis in the BSNIP dataset. The results are shown in Table 1. That the residual is highly useful for prediction is supported by related work manipulating PCA-based identifiability to enhance predictive performance [44]. Age Prediction in the PNC Dataset Figure 3: Age prediction in the PNC dataset. The ensemble of residual and angle basis is slightly but significantly better than the FC from which it was derived. Additionally, we find a strong effect for predicting within race and sex-matched compared to within mixed groups. We next tested the transfer of sex and race prediction models from the PNC to the BSNIP dataset and vice versa. Models were trained wholly on one dataset and evaluated on the other. The results are shown in Table 1. It should be remembered that the PNC dataset is composed of ostensibly normal pre-teens, teens, and young adults, while the BSNIP dataset is composed of adults with schizophrenia-like diseases, their relatives, and normal controls. The high model transfer AUC for race prediction makes the case for biologically significant invariant features. Sex, by contrast, is less stable to model transfer, though prediction is still somewhat robust. It is well-known, for instance, that, on average, women demonstrate stronger within-DMN connectivity than men [11].

Prediction Accuracy, Model Transfer, and Feature Selection
We used both Ridge and Lasso models to estimate the most relevant features for age prediction in the PNC dataset. Features were estimated on 50% of the dataset, with the remaining 50% used in an 80/20 split to train on and validate the selected features. See Supplemental Materials for results.

Effect of the Number of Bases
We find that prediction accuracy increases monotonically with increasing number of bases (see Figure 4), corresponding to decreasing reconstruction error. In contrast, prediction accuracy of the residual decreases monotonically with increasing number of bases. Using the first residual and the 20 th angle basis reconstruction in an ensemble results in a higher accuracy than FC. Using FC twice in an ensemble is not significantly different compared to a single FC-based prediction.

Generation of Synthetic FC
We trained a set of 20 predictive models for age, race, sex, and schizophrenia diagnosis, and used them to generate synthetic FC via the angle basis framework using random seeds. The results for a

Conclusion
In this work, we present a generative model for and decomposition of FC, which requires only a single subject's connectivity matrix as input, and which generates a highly accurate reconstruction using a fraction of the original parameters. We find that both the reconstruction and residual have similar predictive ability, with an ensemble of the two surpassing FC in most cases. Additionally, we find that the residual is highly useful in subject identification or fingerprinting, achieving a nearly 100% subject identification rate on different in-scanner task scans. The estimation of the decomposition is fast, taking seconds for a single subject using a workstation with a mid-priced GPU. Our goal is to use this work as a baseline for the creation of synthetic FC datasets that incorporate information about population characteristics, with the aim to reduce the financial burden of fMRI acquisition.
fMRI and phenotype data came from the Neurodevelopmental Genomics: Trajectories of Complex Phenotypes database of genotypes and phenotypes repository, dbGaP Study Accession ID phs000607.v3.p2, as well as the Bipolar and Schizophrenia Network for Intermediate Phenotypes study (http://b-snip.org/).

B Effect of Jitter vs Angle on Decomposition
We investigated the possibility of using only jitter or only angle as a basis for decomposing FC. Although jitter could be estimated using gradient descent with constant phase angle, a more efficient way is to use the truncated eigendecomposition of the FC. For example, a rank-5 decomposition would be created as follows: where X is a subject's FC,X is the low-rank estimate, and Λ is the ordered diagonal matrix of eigenvalues. This is possible because the FC is a positive semidefinite matrix.
Angle basis decomposition without jitter was estimated using gradient descent. The predictive accuracy of both models is shown in Figure 6.

C Comparison of Linear and Nonlinear Models for Downstream Tasks
We make a comparison between Logistic Regression, an MLP model, and the BrainNetCNN, similar to Pervaiz et al. [36]. As in that work, we find the linear model performed the best, with BrainNetCNN having worse performance (see Table 2). The small number of subjects and high inter-subject variability may hinder the advantage of more expressive models.

D Prediction using the Phase Lock Value Directly
We include in Figure 7 a set of representative PLV connectivities from the PNC dataset. As seen in Table 3, the PLV connectivies themselves are poor predictors of phenotypes.

E Additional Demographic Information
We include more detailed demographic information on the PNC and BSNIP datasets in Figures 8, 9 and 10.

F Generation of Synthetic FC
Synthetic FC was generated by fitting 20 linear predictive models to the BSNIP dataset. The models used were Ridge Regression for age prediction and Logistic Regression for sex, race, and schizophrenia diagnosis prediction. Hyperparameters were the same as in the main paper. Models were fit on 20% random samples of the dataset.
One hundred synthetic subjects were created by initializing an angle basis model with 5 bases to random values, then performing gradient descent on the loss between the FC reconstructed from the angle basis and the specified values. A stop gradient operation was applied to model weights, so only the angle basis values (and consequently FC) could change. The phenotype parameters were set to 30 years for age and ±10 for the race, sex, and schizophrenia diagnosis logits. For reference, the absolute value of logits from the original predictive models ranged from 4 to 6 on their respective training sets. Gradient descent was performed for 100 epochs using the Adam optimizer with a Figure 9: Sex and ethnicity broken down by age in the BSNIP dataset. "s1.0" refers to male and "Other" refers to female. CA is Caucasian Ancestry, Other is African Ancestry. learning rate of 10 −2 and no L2 regularization. The first 8 synthetic FCs for both groups are shown in Figure 11.
It should be noted that true subject FC exhibits far more variation than is captured in the synthetic data (see Figure 12). Nonetheless, we believe that the synthetic FC is useful since it accurately captures the coarse brain network-level differences between groups, and gives a simple visual description of qualitative differences in low-rank brain networks.

G Prediction with Limited Number of Features
We tested prediction on angle basis reconstruction and residual using features selected by Lasso, Ridge Regression, or correlation with the response variable. The results are shown in Figure 13. As expected, Lasso outperformed Ridge. Selecting features by correlation with the response variable was found to be a poor way to select features, likely due to the large multicollinearity present in FC.